
#ifndef __VIRTUAL_SCM_H__
#define __VIRTUAL_SCM_H__

#include <Windows.h>

typedef union {
    SERVICE_TABLE_ENTRYA ServiceStartTableA;
    SERVICE_TABLE_ENTRYW ServiceStartTableW;
}UNION_SERVICE_TABLE_ENTRY, *PUNION_SERVICE_TABLE_ENTRY;

SERVICE_STATUS_HANDLE WINAPI Virtual_RegisterServiceCtrlHandlerEx(
    BOOL bUseEx,
    _In_           LPCWSTR               lpServiceName,
    _In_           LPHANDLER_FUNCTION_EX lpHandlerProc,
    _In_opt_       LPVOID                lpContext);

BOOL Virtual_SetServiceStatus(
    _In_ SERVICE_STATUS_HANDLE hServiceStatus,
    _In_ LPSERVICE_STATUS      lpServiceStatus
);

BOOL WINAPI Virtual_StartServiceCtrlDispatcher(
    BOOL bUnicode,
    CONST  UNION_SERVICE_TABLE_ENTRY* lpTable);


#endif